SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
create function dbo.fnGetWorkingHoursInMonth(
	@currentDate datetime,
	@workingHoursInADay int = null
)
	returns int
as

begin

	if @workingHoursInADay is null
	set @workingHoursInADay = 8
	return dbo.fnGetBusinessDaysInMonth(@currentDate) * @workingHoursInADay
	
end